<template>
  <div class="table-page-search-wrapper" style="margin-top: 20px">
    <a-form-model
      :class="{ ischeck: disableSubmit }"
      :model="projectItem"
      :label-col="labelCol"
      :wrapper-col="wrapperCol"
    >
      <div class="table-page-search-wrapper" style="margin-top: 20px">
        <a-form-model :model="projectItem" :label-col="labelCol" :wrapper-col="wrapperCol">
          <!-- 资产总额 -->
          <a-row>
            <a-col>
              <a-form-model-item label="设置金额阈值">
                <a-row :gutter="12">
                  <a-col  class="item_line">
                    <span>增：</span>
                    <a-input v-model="projectItem.num" class="addandsub_input">
                      <a-button
                        slot="addonAfter"
                        class="btn_addandsub"
                        @click="addNumber('num')"
                        icon="plus"
                      ></a-button>
                      <a-button
                        slot="addonBefore"
                        class="btn_addandsub"
                        @click="subNumber('num')"
                        icon="minus"
                      ></a-button>
                    </a-input>
                  </a-col>
                </a-row>
              </a-form-model-item>
            </a-col>
          </a-row>
        </a-form-model>
      </div>
    </a-form-model>
  </div>
</template>

<script>
export default {
  name: 'AnalysisIndexby',
  props: ['projectItem', 'disableSubmit'],
  data() {
    return {
      labelCol: { span: 6 },
      wrapperCol: { span: 18 },
    }
  },
  methods: {
    addNumber(mysite) {
      this.$emit('addNumber', mysite)
    },
    subNumber(mysite) {
      this.$emit('subNumber', mysite)
    },
  },
}
</script>

<style lang="less" scoped>
.btn_position {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}
.item_line {
  display: flex;
  align-items: center;
}
.addandsub_input {
  width: 130px;
  /deep/ .ant-input-group-addon {
    padding: 0;
  }
  /deep/ .ant-input-group {
    width: 125px;
  }
  .btn_addandsub {
    height: 30px;
    width: 25px;
    padding: 0;
    border-color: #f9f9f9;
    background-color: #f9f9f9;
    .add {
    }
  }
}
.ischeck {
  /deep/.ant-input-disabled {
    color: black;
  }
}
</style>